const Sequelize = require('sequelize');
module.exports = function(sequelize, DataTypes) {
  return sequelize.define('con_check_content', {
    checkContentId: {
      type: DataTypes.BIGINT,
      allowNull: false,
      primaryKey: true,
      comment: "合同检查内容ID",
      field: 'check_content_id'
    },
    checkItem: {
      type: DataTypes.STRING(20),
      allowNull: false,
      comment: "检查事项:数据字典",
      field: 'check_item'
    },
    checkInfoId: {
      type: DataTypes.BIGINT,
      allowNull: false,
      comment: "项目id",
      field: 'check_info_id'
    },
    conslicemasterId: {
      type: DataTypes.BIGINT,
      allowNull: false,
      comment: "施工项目ID",
      field: 'conslicemaster_id'
    },
    remark: {
      type: DataTypes.STRING(512),
      allowNull: true,
      comment: "备注"
    },
    isDeleted: {
      type: DataTypes.BOOLEAN,
      allowNull: false,
      field: 'is_deleted'
    },
    flag: {
      type: DataTypes.CHAR(1),
      allowNull: false,
      comment: "1是 0否"
    }
  }, {
    sequelize,
    tableName: 'con_check_content',
    timestamps: false,
    indexes: [
      {
        name: "PRIMARY",
        unique: true,
        using: "BTREE",
        fields: [
          { name: "check_content_id" },
        ]
      },
    ]
  });
};
